package httpx

type Resp struct {
	Success bool        `json:"success"`
	Data    interface{} `json:"data"`
}

func NewResp(success bool, data interface{}) *Resp {
	return &Resp{Success: success, Data: data}
}

type PageResp struct {
	Success bool        `json:"success"`
	Total   int64       `json:"total"`
	Data    interface{} `json:"data"`
}

func NewPageResp(success bool, total int64, data interface{}) *PageResp {
	return &PageResp{Success: success, Total: total, Data: data}
}
